// ++++++++++++++++++++++++++++++++++++++++
// 《零基础Go语言算法实战》源码
// ++++++++++++++++++++++++++++++++++++++++
// Author:廖显东（ShirDon）
// Blog:https://www.shirdon.com/
// Gitee:https://gitee.com/shirdonl/goAlgorithms.git
// Buy link :https://item.jd.com/14101229.html
// ++++++++++++++++++++++++++++++++++++++++

package main

import (
	"fmt"
	"time"
)

func printNumbers() {
	for i := 6; i <= 8; i++ {
		time.Sleep(200 * time.Millisecond)
		fmt.Printf("%d ", i)
	}
}
func printChars() {
	for i := 'x'; i <= 'z'; i++ {
		time.Sleep(300 * time.Millisecond)
		fmt.Printf("%c ", i)
	}
}
func main() {
	go printNumbers()
	go printChars()
	time.Sleep(2000 * time.Millisecond)
	fmt.Println("main 结束～")
}

//$ go run goroutine2.go
//6 x 7 y 8 z main 结束～
